import request from '@/utils/request'

// 查询治疗方案列表
export function listCure(query) {
  return request({
    url: '/masterdocker/cure/list',
    method: 'get',
    params: query
  })
}

// 查询治疗方案详细
export function getCure(cureId) {
  return request({
    url: '/masterdocker/cure/' + cureId,
    method: 'get'
  })
}

// 新增治疗方案
export function addCure(data) {
  return request({
    url: '/masterdocker/cure',
    method: 'post',
    data: data
  })
}

// 修改治疗方案
export function updateCure(data) {
  return request({
    url: '/masterdocker/cure',
    method: 'put',
    data: data
  })
}

// 删除治疗方案
export function delCure(cureId) {
  return request({
    url: '/masterdocker/cure/' + cureId,
    method: 'delete'
  })
}

export function allCure(query) {
  return request({
    url: '/masterdocker/cure/allCure',
    method: 'get',
    params: query
  })
}

// 查询治疗方案详细
export function getTyPrescriptionInfoById(id) {
  return request({
    url: '/masterdocker/tyPrescriptionInfo/getTyPrescriptionInfoById',
    method: 'get',
    params: { prescriptionInfoId: id }
  })
}

export function allPatient(query) {
  return request({
    url: '/tyPatient/getAllPatient',
    method: 'get',
    params: query
  })
}

export function allDoctor(query) {
  return request({
    url: '/tyEmployee/getAllEmployee',
    method: 'get',
    params: query
  })
}
